<?php

class ArrivalRate {
	
	var $time;
	var $classAndMethod;
	
	function __construct($identifier)
	{
		$this->classAndMethod = $identifier;
		$this->time = $this->getmicrotime();
		$db = new ezSQL_mysql(USERNAME, PASSWORD, DATABASE, HOSTNAME);
		$db->query("INSERT INTO arrival_rate (method, microtime) 
						   VALUES ('$this->classAndMethod', '$this->time')");
	}
	
	function getmicrotime()
	{
	    list($u, $s) = explode(' ',microtime());
	    return bcadd($u, $s, 8);
	}	
}
//EOF ArrivalRate.php
